package com.chixing.day12_date_factory;

public class PointerTest {
    public static void main(String[] args) {

        //菱形语法
        Pointer<Integer> pointer1 = new Pointer<>();
        pointer1.setX(15);
        pointer1.setY(24);
        System.out.println(pointer1);

        Pointer<Integer> pointer2 = new Pointer<>(20,30);
        System.out.println(pointer2);

        Pointer<Double> pointer3 = new Pointer<>();
        pointer3.setX(2.3);
        pointer3.setY(9.4);
        System.out.println(pointer3);

        Pointer<String> pointer4 = new Pointer<>("东经130","北纬35");
        System.out.println(pointer4);

        Pointer<String> pointer5 = new Pointer<>("东经140°","北纬45d°");


    }

}
